package com.restaurant.application.indexes.couponmanagelist.support;

import com.google.common.collect.Lists;
import com.nebutown.generation.Convert;
import com.nebutown.generation.PickableBean;
import java.lang.String;
import java.util.List;

public class ShowInfoData implements PickableBean {
    
    public static final String FN_ID = "id";
    public static final String FN_TYPE = "type";
    public static final String FN_NAME = "name";
    public static final String FN_RECEIVETIME = "receiveTime";
    public static final String FN_ENDTIME = "endTime";
    public static final String FN_SHOPNAME = "shopName";
    public static final String FN_STATE = "state";
    public static final String FN_LIMITID = "limitId";
    public static final String FN_LIMITACCOUNT = "limitAccount";
    public static final String FN_TOTALAMOUNT = "totalAmount";
    public static final String FN_AMOUNT = "amount";
    public static final String FN_MODIFYPATH = "modifyPath";
    
    public static final List<String> FIELD_NAMES = Lists.newArrayList(
             FN_ID,
             FN_TYPE,
             FN_NAME,
             FN_RECEIVETIME,
             FN_ENDTIME,
             FN_SHOPNAME,
             FN_STATE,
             FN_LIMITID,
             FN_LIMITACCOUNT,
             FN_TOTALAMOUNT,
             FN_AMOUNT,
             FN_MODIFYPATH);
    
    private String id;
    private String type;
    private String name;
    private String receiveTime;
    private String endTime;
    private String shopName;
    private String state;
    private String limitId;
    private String limitAccount;
    private String totalAmount;
    private String amount;
    private String modifyPath;
    
    public ShowInfoData(String id, String type, String name, String receiveTime, String endTime, String shopName, String state, String limitId, String limitAccount, String totalAmount, String amount, String modifyPath) {
        setId(id);
        setType(type);
        setName(name);
        setReceiveTime(receiveTime);
        setEndTime(endTime);
        setShopName(shopName);
        setState(state);
        setLimitId(limitId);
        setLimitAccount(limitAccount);
        setTotalAmount(totalAmount);
        setAmount(amount);
        setModifyPath(modifyPath);
    }
    
    public ShowInfoData() {
    }
    
    public ShowInfoData duplicate() {
        ShowInfoData result = new ShowInfoData();
        result.id = this.id;
        result.type = this.type;
        result.name = this.name;
        result.receiveTime = this.receiveTime;
        result.endTime = this.endTime;
        result.shopName = this.shopName;
        result.state = this.state;
        result.limitId = this.limitId;
        result.limitAccount = this.limitAccount;
        result.totalAmount = this.totalAmount;
        result.amount = this.amount;
        result.modifyPath = this.modifyPath;
        return result;
    }
    
    @Override
    public String toString() {
        return Convert.toJson(this);
    }
    
    public String getId() {
        return id;
    }
    
    public void  setId(String value) {
        this.id = value;
    }
    
    public ShowInfoData withId(String value) {
        setId(value);
        return this;
    }
    
    public ShowInfoData withId(String value, String defaultValue) {
        setId(value == null ? defaultValue : value);
        return this;
    }
    
    public String getType() {
        return type;
    }
    
    public void  setType(String value) {
        this.type = value;
    }
    
    public ShowInfoData withType(String value) {
        setType(value);
        return this;
    }
    
    public ShowInfoData withType(String value, String defaultValue) {
        setType(value == null ? defaultValue : value);
        return this;
    }
    
    public String getName() {
        return name;
    }
    
    public void  setName(String value) {
        this.name = value;
    }
    
    public ShowInfoData withName(String value) {
        setName(value);
        return this;
    }
    
    public ShowInfoData withName(String value, String defaultValue) {
        setName(value == null ? defaultValue : value);
        return this;
    }
    
    public String getReceiveTime() {
        return receiveTime;
    }
    
    public void  setReceiveTime(String value) {
        this.receiveTime = value;
    }
    
    public ShowInfoData withReceiveTime(String value) {
        setReceiveTime(value);
        return this;
    }
    
    public ShowInfoData withReceiveTime(String value, String defaultValue) {
        setReceiveTime(value == null ? defaultValue : value);
        return this;
    }
    
    public String getEndTime() {
        return endTime;
    }
    
    public void  setEndTime(String value) {
        this.endTime = value;
    }
    
    public ShowInfoData withEndTime(String value) {
        setEndTime(value);
        return this;
    }
    
    public ShowInfoData withEndTime(String value, String defaultValue) {
        setEndTime(value == null ? defaultValue : value);
        return this;
    }
    
    public String getShopName() {
        return shopName;
    }
    
    public void  setShopName(String value) {
        this.shopName = value;
    }
    
    public ShowInfoData withShopName(String value) {
        setShopName(value);
        return this;
    }
    
    public ShowInfoData withShopName(String value, String defaultValue) {
        setShopName(value == null ? defaultValue : value);
        return this;
    }
    
    public String getState() {
        return state;
    }
    
    public void  setState(String value) {
        this.state = value;
    }
    
    public ShowInfoData withState(String value) {
        setState(value);
        return this;
    }
    
    public ShowInfoData withState(String value, String defaultValue) {
        setState(value == null ? defaultValue : value);
        return this;
    }
    
    public String getLimitId() {
        return limitId;
    }
    
    public void  setLimitId(String value) {
        this.limitId = value;
    }
    
    public ShowInfoData withLimitId(String value) {
        setLimitId(value);
        return this;
    }
    
    public ShowInfoData withLimitId(String value, String defaultValue) {
        setLimitId(value == null ? defaultValue : value);
        return this;
    }
    
    public String getLimitAccount() {
        return limitAccount;
    }
    
    public void  setLimitAccount(String value) {
        this.limitAccount = value;
    }
    
    public ShowInfoData withLimitAccount(String value) {
        setLimitAccount(value);
        return this;
    }
    
    public ShowInfoData withLimitAccount(String value, String defaultValue) {
        setLimitAccount(value == null ? defaultValue : value);
        return this;
    }
    
    public String getTotalAmount() {
        return totalAmount;
    }
    
    public void  setTotalAmount(String value) {
        this.totalAmount = value;
    }
    
    public ShowInfoData withTotalAmount(String value) {
        setTotalAmount(value);
        return this;
    }
    
    public ShowInfoData withTotalAmount(String value, String defaultValue) {
        setTotalAmount(value == null ? defaultValue : value);
        return this;
    }
    
    public String getAmount() {
        return amount;
    }
    
    public void  setAmount(String value) {
        this.amount = value;
    }
    
    public ShowInfoData withAmount(String value) {
        setAmount(value);
        return this;
    }
    
    public ShowInfoData withAmount(String value, String defaultValue) {
        setAmount(value == null ? defaultValue : value);
        return this;
    }
    
    public String getModifyPath() {
        return modifyPath;
    }
    
    public void  setModifyPath(String value) {
        this.modifyPath = value;
    }
    
    public ShowInfoData withModifyPath(String value) {
        setModifyPath(value);
        return this;
    }
    
    public ShowInfoData withModifyPath(String value, String defaultValue) {
        setModifyPath(value == null ? defaultValue : value);
        return this;
    }
    
    public Object getValueOf(String name) {
        switch(name) {
        case "id": return getId();
        case "type": return getType();
        case "name": return getName();
        case "receiveTime": return getReceiveTime();
        case "endTime": return getEndTime();
        case "shopName": return getShopName();
        case "state": return getState();
        case "limitId": return getLimitId();
        case "limitAccount": return getLimitAccount();
        case "totalAmount": return getTotalAmount();
        case "amount": return getAmount();
        case "modifyPath": return getModifyPath();
        }
        return null;
    }
    
    public boolean hasField(String name) {
        return FIELD_NAMES.contains(name);
    }
    
    @Override
    public int hashCode() {
        return signature().hashCode();
    }
    
    @Override
    public boolean equals(Object o) {
        if(!(o instanceof ShowInfoData)) return false;
        return signature().equals(((ShowInfoData)o).signature());
    }
    
    public String signature() {
        throw new RuntimeException("Bean ShowInfoData has no signature defined, no hash code or equals possible.");
    }
}
